/*--------------------------------------------------------------------------------------*\
**
** adv_obelisk.h
**
** Heroes IV
** Copyright 2000, The 3DO Company
**
\*--------------------------------------------------------------------------------------*/

#ifndef ADV_BORDER_GATE_H_INCLUDED
#define ADV_BORDER_GATE_H_INCLUDED

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include <bitset>

#include "adv_object_type.h"
#include "bool_array.h"
#include "hero.h"
#include "stationary_adventure_object.h"

class  t_adventure_map;

typedef std::bitset<k_obelisk_color_count>	t_obelisk_flags;

// Obelisk.
class t_adv_obelisk : public t_stationary_adventure_object
{
public:
                
    t_adv_obelisk(  std::string const& source );
    void			activate_trigger( t_army* army, t_adv_map_point const& point, 
		                              t_direction direction, t_adventure_frame* frame );
	virtual float	ai_value( t_adventure_ai const& ai, t_creature_array const& army, int move_cost ) const;	
	virtual int		get_version() const;
    virtual void    initialize( t_adventure_map& map );
	virtual void	place( t_adventure_map &map, t_adv_map_point const&	point );
	virtual bool    read( std::streambuf&						stream, 
					      t_qualified_adv_object_type const&	type,
					      int									version );
	virtual bool	write( std::streambuf & stream ) const;

protected:

	t_bool_array    m_visited;

    void    place_artifact( t_adventure_map * map_ptr, t_army * army );
};

typedef std::vector< t_adv_obelisk >				t_obelisk_list;

#endif
